package com.hyh.ui.localnumber;

import android.app.Activity;
import android.content.Context;
import android.content.Intent;
import android.widget.ImageView;

import com.hyh.Contact.Contact;
import com.hyh.ui.base.BaseActivity;
import com.hyh.util.SharePreferenceUtil;
import com.hyh.videochat.R;

import butterknife.BindView;

/**
 * Created by Administrator on 2019/1/26.
 */

public class ShowImgActivity extends BaseActivity {

    @BindView(R.id.iv_image)
    ImageView ivImage;
    public static void startActivity(Activity activity,int imageId){
        Intent intent = new Intent(activity,ShowImgActivity.class);
        intent.putExtra(Contact.Contact_Img,imageId);
        activity.startActivity(intent);
    }

    @Override
    public int getLayout() {
        return R.layout.activity_show_img;
    }

    @Override
    public void getIntentExtras(Intent intent) {
        int imgId = intent.getIntExtra(Contact.Contact_Img,-1);
        if(imgId!=-1){
            ivImage.setImageResource(imgId);
        }
    }

    @Override
    public void initDataAndEvent() {

    }
}
